// 班级升级的时候备份学生的信息
class StudentBackup {
    String name = ''; // 姓名    
    String sex = ''; //性别
    Date birthday ; // 生日
    ClassBackup classBackup;
    String level = '';
  
    Student  student;
    String term //学期
    int year = Calendar.instance.get(Calendar.YEAR)

    static mapping = {
       table 'xedu_student_backup'
    }

    static constraints = {
     
        name(size: 1..50, blank: false);        
        sex(size: 1..4,blank: true)
        birthday(nullable:true)
        level()
        term()
      
        student(   )
        classBackup(   ) 

    }


    String toString() {
        "${name}"
    }
  
}
